package com.atcc.test.service;

import java.util.List;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.atcc.test.pojo.User;


//@FeignClient(value="provider-x001")
@FeignClient(value="provider-x001",fallbackFactory=UserServiceFallBackFactory.class)
public interface UserService {
	
	@RequestMapping(method=RequestMethod.GET,value="/test")
	public List<User> getAll();
	
	@GetMapping("/test/{id}")
	public User getUserById(@PathVariable("id") Long id);

}
